package com.jt.auth.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller//返回的是一个页面，@ResController返回的是一个字符串
public class PageController {

//    @ResponseBody //+@Controller  放在一起等效  @ResController
    @PostMapping("/doIndex")
    public String doIndex(){
        System.out.println("===Doindex===");
        return "redirect:/index.html";
    }
}
